package com.example.web.merchant.mapper;

import com.example.web.merchant.MerchantRequestParams;
import com.example.web.merchant.pojo.Merchant;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface MerchantMapper {


    int add(MerchantRequestParams merchantRequestParams);
    // 商家是否注册过（根据商家的账号去查）
    Merchant findByMname(String mname);

    // 商家的登录
    Merchant login(MerchantRequestParams merchantRequestParams);
    int update(Merchant merchantRequestParams);
    List<Merchant> list();

    int updateStatusBymId(Integer mid);

    int updateStatusByMid(Integer mid);

    List<Merchant> findByCondition(String mrealname);
}